﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using linkedin_bot_demo.Models;
using System.Collections.ObjectModel;
using System.Windows.Input;
using linkedin_bot_demo.Common;

namespace linkedin_bot_demo.ViewModels
{
    public class PostGroupViewModel : ViewModel
    {
        private PostGroupModel _model;

        public PostGroupViewModel(PostGroupModel model)
        {
            if (model == null) throw new ArgumentNullException();
            this._model = model;
        }

        public String Post 
        { 
            get { return _model.Post; }
            set
            {
                this._model.Post = value;
            }
        }

        private DelegateCommand _sendGroupPostCommand;
        public ICommand SendGroupPostCommand
        {
            get { return _sendGroupPostCommand ?? (_sendGroupPostCommand = new DelegateCommand(OnSendGroupPost)); }
        }

        private void OnSendGroupPost()
        {
            //using (LinkedinApiClient api = new LinkedinApiClient("77slv7rweme81w", "kg4UUHYzDlnSKGtQ"))
            //{
                
            //}
        }
    }
}
